export default function toPayPage(
  url: string,
  options: { order_id: string; redirect_url: string }
) {
  const redirectUrl = encodeURIComponent(
    `${window.location.origin}/?redirect_url=${encodeURIComponent(encodeURIComponent(`${options.redirect_url + `&orderId=${options.order_id}`}`))}`
  );
  return `${url}&url=${redirectUrl}`;
}
